/* eslint-disable */
import request from "@/util/request";

/** 此处后端没有提供注释 POST /scoring/result/add */
export async function addSortingResult(
  body: API.ScoringResultAddDTO,
  options?: { [key: string]: any }
) {
  return request<API.Result>("/scoring/result/add", {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    data: body,
    ...(options || {}),
  });
}

/** 此处后端没有提供注释 POST /scoring/result/delete */
export async function delete1(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.delete1Params,
  options?: { [key: string]: any }
) {
  return request<API.Result>("/scoring/result/delete", {
    method: "POST",
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** 此处后端没有提供注释 POST /scoring/result/query/all */
export async function queryAll(
  body: API.ScoringResultQueryDTO,
  options?: { [key: string]: any }
) {
  return request<API.ResultResultPageScoringResultVo>(
    "/scoring/result/query/all",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    }
  );
}

/** 此处后端没有提供注释 GET /scoring/result/query/one/${param0} */
export async function queryOneById2(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.queryOneById2Params,
  options?: { [key: string]: any }
) {
  const { id: param0, ...queryParams } = params;
  return request<API.ResultScoringResultVo>(
    `/scoring/result/query/one/${param0}`,
    {
      method: "GET",
      params: { ...queryParams },
      ...(options || {}),
    }
  );
}

/** 此处后端没有提供注释 POST /scoring/result/update */
export async function update2(
  body: API.ScoringResultUpdateDTO,
  options?: { [key: string]: any }
) {
  return request<API.Result>("/scoring/result/update", {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    data: body,
    ...(options || {}),
  });
}
